package com.farsunset.ichat.common.util;

import com.farsunset.cim.nio.session.CIMSession;
import com.farsunset.cim.nio.session.ClusterSession;

public class SessionConvertBean {
	
	public static ClusterSession convert(CIMSession localSession){		
		ClusterSession clusterSession = new ClusterSession();
		clusterSession.setAccount(localSession.getAccount());
		clusterSession.setHost(localSession.getHost());
		clusterSession.setNid(localSession.getNid());
		clusterSession.setGid(localSession.getGid());
		clusterSession.setBindTime(localSession.getBindTime());
		clusterSession.setChannel(localSession.getChannel());
		clusterSession.setDeviceId(localSession.getDeviceId());
		clusterSession.setDeviceModel(localSession.getDeviceModel());		
		clusterSession.setHeartbeat(localSession.getHeartbeat());
		clusterSession.setDeviceToken(localSession.getDeviceToken());
		return clusterSession;		
	}
	
	
	

}
